import request from '@/utils/request'

// 查询领用出库单列表
export function listBizReceiveOrder (query) {
  return request({
    url: '/biz/bizReceiveOrder/list',
    method: 'get',
    params: query
  })
}

// 查询领用出库单详细
export function getBizReceiveOrder (id) {
  return request({
    url: '/biz/bizReceiveOrder/' + id,
    method: 'get'
  })
}

// 新增领用出库单
export function addBizReceiveOrder (data) {
  return request({
    url: '/biz/bizReceiveOrder',
    method: 'post',
    data: data
  })
}

// 修改领用出库单
export function updateBizReceiveOrder (data) {
  return request({
    url: '/biz/bizReceiveOrder',
    method: 'put',
    data: data
  })
}

// 删除领用出库单
export function delBizReceiveOrder (id) {
  return request({
    url: '/biz/bizReceiveOrder/' + id,
    method: 'delete'
  })
}


// 导出领用出库单
export function exportBizReceiveOrder (query) {
  return request({
    url: '/biz/bizReceiveOrder/export',
    method: 'get',
    params: query
  })
}

// 获取初始化数据
export function getInitData (dictTypes) {
  return request({
    url: '/biz/bizReceiveOrder/getInitData/' + dictTypes,
    method: 'get'
  })
}


//客户应收期初审核
export function auditBizReceiveOrder (id) {
  return request({
    url: '/biz/bizReceiveOrder/audit/' + id,
    method: 'get'
  })
}

//客户应收期初反审核
export function doAuditBizReceiveOrder (id) {
  return request({
    url: '/biz/bizReceiveOrder/doAudit/' + id,
    method: 'get'
  })
}
